<style type="text/css">
.carousel-inner .item img{
	max-width: 100%;
    max-height: 100%;
    vertical-align: middle;
	height:82px;
}
.star-rate {margin-left:0}
.fe-floatright-bottom a {
    display: block;
    width: 1.6rem;
    height: 1.6rem;
    border-radius: 100%;
    background-color: #ff9999;
    color: #fff;
    line-height: 0.7rem;
	font-size:0.45rem;
    margin: 0.5rem auto;
    margin-right: 0;
}
.fe-floatright-bottom a .icon {
    color: #fff;
    font-size: 0.6rem;
    height: 0.6rem;
	line-height: 1rem;
    opacity: 1;
}
</style>
<div class='fui-page fui-page-current' ng-if="pagedata.op=='main'">
    <div class="fui-content" style="margin-bottom:2.2rem">
	<div class="sort" style="top:0.2rem">
		<div class="fui-list-group" style="background:#fff;padding:0.25rem 0.5rem;margin-top:0">
					<div class="fui-list" ng-repeat="item in pagedata.list" style="border-radius:0.5rem;margin-bottom:0.3rem;background:#f2f2f2">
					   <div class="fui-list-inner" style="margin-top:0.16rem">
							<div class="title" style="font-size:0.76rem;height:2rem;line-height:2rem">
								<span>{{item.name}}</span>
								<span ng-if="item.isfa==1" style="padding-left:0.5rem">
									<div class="btn btn-sm btn-default-o order-delete">本人</div>
								</span>
								<div ng-if="item.isfa!=1" ng-click="access_json('jy_zhongyi/body_list/edit/id='+item.id)" class="btn btn-sm btn-default-o">编辑</div>
								<div ng-if="item.isfa!=1" ng-click="post({'id':item.id},'jy_zhongyi/body_list//delete/')" class="btn btn-sm btn-red-o order-delete">删除</div>
							</div>
							<div class="subtitle" style="-webkit-line-clamp:2;height:1.5rem">
								{{item.year}}岁 | {{item.sex}} | {{item.mobile}}
							</div>
						</div>
						<div ng-click="access_json('jy_zhongyi/yuyue_order//id='+item.id)" class='fui-list-angle' style="color:#C03E3E">
							 <div class="angle">看诊记录</div>
						</div>
					</div>
		</div>
		<div ng-show="pagedata.loading" class='infinite-loading'><span class='fui-preloader'></span><span style="margin-left:1.5rem"> 正在加载...</span></div>
		<div class="content-empty" ng-show="!pagedata.list || pagedata.list.length == 0 ">
		  <i class="icon jinyunicon icon-cry" style="width: 6rem;margin-bottom: 0.5rem;"></i><br/><p style="color: #999;font-size: .75rem">暂时没有添加家人！</p> 
		</div>
		<div style="text-align:center;margin-top:1rem">
			<a href="javascript:;" ng-click="access_json('jy_zhongyi/body_list/edit/')" class='btn btn-sm btn-danger-o external'style="border-radius: 100px;width:  7rem;font-size: .75rem">添加家人</a>
		</div>
	</div>
</div>
</div>
<div class='fui-page fui-page-current' ng-if="pagedata.op=='edit'">
    <div class='fui-content member-page'>
		<div class="fui-cell-group"  style="margin-top:0">
			<div class="fui-cell-title bold" style="padding: 0.5rem 0.65rem;">家人信息</div>
			<div class="weui_cells weui_cells_form" style="margin-top:-0.5rem">
					<div class="weui_cell">
						<div class="weui_cell_hd"><label class="weui_label">家人照片</label></div>
						<div class="weui_cell_bd weui_cell_primary" >
							<ul class="weui_uploader_files" ng-if="pagedata.item.avatar">
							  <li class="weui_uploader_file" style="background-image:url({{tomedia(pagedata.item.avatar)}})"></li>
							</ul>
							<div class="weui_uploader_input_wrp">
								 <input class="weui_uploader_input" ng-model="pagedata.item.data" ng-click="image(pagedata.item,'avatar')" accept="image/jpg,image/jpeg,image/png,image/gif" multiple="">
							</div>
						</div>
					</div>
					<div class="weui_cell">
						<div class="weui_cell_hd"><label class="weui_label">家人姓名</label></div>
						<div class="weui_cell_bd weui_cell_primary">
							<input ng-model="pagedata.item.name" class="weui_input" type="text" placeholder="请输入家人姓名">
						</div>
					</div>
					<div class="weui_cell">
						<div class="weui_cell_hd"><label class="weui_label">家人生日</label></div>
						<div class="weui_cell_bd weui_cell_primary">
							 <input class="datetimepicker weui_input" type="text" name="agetime" onchange="window.scope.pagedata.item.agetime=$(this).val()" ng-model="pagedata.item.agetime" placeholder="请选择"/>
						</div>
						<script type="text/javascript">
						require(["datetimepicker"], function(){
							$(function(){
									var fmt;
									fmt="Y-m-d";
									var option = {
										lang : "zh",
										step : 5,
										timepicker : true,
										closeOnDateSelect : true,
										format : fmt,
										yearStart: 1920,
										yearEnd: 2030,
										
									};
								$(".datetimepicker[name = 'agetime']").datetimepicker(option);
							});
						});
					</script>
					</div>
					<div class="weui_cell">
						<div class="weui_cell_hd"><label class="weui_label">家人性别</label></div>
						<div class="weui_cell_bd weui_cell_primary">
									<select ng-model="pagedata.item.sex" class="form-control tpl-province">
									<option value="" selected="selected">选择性别</option>
									<option value="2" ng-selected="pagedata.item.sex==2">女</option>
									<option value="1" ng-selected="pagedata.item.sex==1">男</option>
									</select>
						</div>
					</div>
			</div>
			
		</div>
		<div class="weui_btn_area" style="margin:1rem 4rem 3.8rem 4rem">
				<a  class="weui_btn weui_btn_red" style="border-radius:1rem" href="javascript:" ng-click="post(pagedata.item,'jy_zhongyi/body_list/post/')">提交保存</a>
		</div>
</div>
</div>
<div ng-include="sys_html('_footer')"></div>
<script type="text/javascript">
//手机软键盘--搜索
$("body").keydown(function() {
    if (event.keyCode == "13") {
        $('#searchsub').click();
    }
});
scope.pagedata.loading = true;
scope.pagedata.type=0	
scope.tool.get_list('jy_zhongyi/body_list/getlist/',true);
scope.pagedata.scroll_bottom=function(){
	scope.tool.get_list('jy_zhongyi/body_list/getlist/');
}
//手机软键盘--搜索
$("body").keydown(function() {
    if (event.keyCode == "13") {
        $('#searchsub').click();
    }
});
</script>